﻿<Window x:Class="SSCAI.Client.SnWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="SnWindow" Height="625" Width="545">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="50"></RowDefinition>
            <RowDefinition Height="*"></RowDefinition>
        </Grid.RowDefinitions>
        <StackPanel Grid.Column="0" Grid.Row="1" Orientation="Vertical">
            <DataGrid Name="dgSn" Height="600"  AutoGenerateColumns="False" ItemsSource="{Binding SnsProperty}" ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto">
                <DataGrid.Columns>
                    <DataGridTextColumn Header="序号" Binding="{Binding Id, Mode=OneWay}" Width="50" />
                    <DataGridTextColumn Header="账号" Binding="{Binding UserName, Mode=OneWay}" Width="70" />
                    <DataGridTextColumn Header="过期日期" Binding="{Binding ExpiredDate, Mode=OneWay}" Width="100"/>
                    <DataGridTextColumn Header="激活码" Binding="{Binding Sn, Mode=OneWay}" Width="250"/>
                </DataGrid.Columns>
            </DataGrid>
            <ProgressBar Name="pbLotterys"  Height="15" Value="0"/>
        </StackPanel>
        <ComboBox Name="cmbDays" HorizontalAlignment="Left" Margin="10,10,0,0" VerticalAlignment="Top" Width="120"/>
        <Button Content="生成序列号" HorizontalAlignment="Left" Margin="146,10,0,0" VerticalAlignment="Top" Width="75" Click="Button_Click"/>
        <Button Content="导出CSV" HorizontalAlignment="Left" Margin="452,12,0,0" VerticalAlignment="Top" Width="75" Click="Button_Click_1"/>
    </Grid>
</Window>
